'use strict'
const path = require('path');

function resolve(dir) {
    return path.join(__dirname, dir)
}

module.exports = {
    publicPath: './',
    lintOnSave: false,
    chainWebpack: (config) => {
        config.resolve.alias
            .set('@$', resolve('./src'))
            .set('assets', resolve('./src/assets'))
            .set('components', resolve('./src/components'))
            .set('views', resolve('./src/views'))
            .set('js', resolve('./src/js'))
    },
    devServer: {
        open: false, //是否自动弹出浏览器页面
        host: "localhost",
        port: '81',
        https: false,   //是否使用https协议
        hotOnly: true  //是否开启热更新
    },
    pluginOptions: {
        plugins: ['syntax-dynamic-import']
    }


}




